package com.atguigu.com.miaosha.scheduled;

import com.atguigu.com.miaosha.service.SecKillService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Async;
import org.springframework.scheduling.annotation.EnableScheduling;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Service;

/**
 * @author 满超
 * @date 2020/07/03
 * 商品秒杀服务
 **/
@Service
public class CommodityPike {

    @Autowired
    SecKillService secKillService;

    //@Async //异步任务
    //@Scheduled(cron = "0 0 15 * * ? ")//定时任务
    //public void uploadSec() {
    //    //自动上架每天最新秒杀商品
    //    secKillService.uploadSec();
    //}
}